<%= f.input :caption, as: ingredient.settings[:caption_as_textarea] ? 'text' : 'string' %>
<%= f.input :title %>
<%= f.input :alt_tag, as: :text, placeholder: ingredient.alt_text(language: @language), input_html: {rows: 4} %>
<%- if ingredient.settings[:sizes].present? && ingredient.settings[:srcset].blank? -%>
  <%= f.input :render_size,
    collection: [
      [Alchemy.t('Layout default'), ""]
    ] + ingredient.settings[:sizes].to_a,
    include_blank: false %>
<%- end -%>
<%- if ingredient.settings[:css_classes].present? -%>
  <% css_classes = ingredient.settings[:css_classes] %>
  <% css_classes_collection = case css_classes.first
    when Array
      then css_classes
    else
      css_classes.map do |klass|
        [Alchemy.t(klass, scope: "picture_ingredients.css_classes", default: ingredient.css_class&.camelcase), klass]
      end
    end %>
  <%= f.input :css_class, collection: css_classes_collection, include_blank: false %>
<%- end -%>
